<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
</head>
<body>
    <script>
        let arr =[1,2,3]
        let[a,b,c] = arr
        console.log(a,b,c)

        let[m,n] = arr;
        console.log(m,n)

        let[x,y,z,f] = arr;
        console.log(x,y,z,f)

        let person ={id:1,name:"dkfjdk"}
        let{id:kk,name} = person;
        console.log(kk,name);



        console.log("&&&&&&&&&&&&&&&&&")

        function method1([a,b]){
            console.log(a,b);
        }
        method1([1,2]);
    </script>
</body>
</html>